package site.jlopen.components.entity;

import java.util.ArrayList;
import java.util.List;

import lombok.Data;

@Data
public class GraphNode {
	
	private String id;
	
	private String type;

	private String shape;

	private String label;

	private String desc;

	private List<String> ports;

	public GraphNode(String label, String id) {
		super();
		this.id = id;
		this.shape = "custom-html";
		this.label = label;
		this.ports = new ArrayList<String>();
	}
	
	public GraphNode addPort(String port) {
		this.ports.add(port);
		return this;
	}
	
	public GraphNode addDesc(String desc) {
		this.desc = desc;
		return this;
	}

	public GraphNode TRUSTEDFLOW() {
		this.type = "TrustedFlow";
		return this;
	}

	public GraphNode SECRETFLOW() {
		this.type = "SecretFlow";
		return this;
	}

	public GraphNode CUSTOMFLOW() {
		this.type = "CustomFlow";
		return this;
	}


	
	
}
